#ifndef COMMONTYPE_H
#define COMMONTYPE_H

#include <QString>
#include <vector>
#include <QMessageBox>
#include <QDebug>

typedef enum {
    RESSTATE_NULL = 0,
    RESSTATE_NOT_CHECKED_IN,    //未签到
    RESSTATE_CHECKED_IN         //已签到
}ResState;

typedef enum {
    SEATSTATE_FREE = 0,
    SEATSTATE_BUSY
} SeatState;

typedef struct StuData{
    QString stuid;
    QString name;
    QString passwd;
    QString type;
    int resState;
    QString resSeatAddr;
    QString resTime;
    int limit;
    QString limitTime;
    int limitCnt;
}StuData;

typedef struct SeatInfo{
    int seatState;
    QString seatAddr;
    QString stuid;
    QString startTime;
    QString endTime;
    bool isOnline;
}SeatInfo;

typedef struct SqlTableData{
    int row;
    std::vector<QString> rowData;
}SqlTableData;

typedef struct SqlItemData{
    QString key;
    QString value;
}SqlItemData;

#endif // COMMONTYPE_H
